<?xml version="1.0" encoding="utf-8"?>
<Content type="xform" name="EditContent">
	<model>
		<instance>
			<tblContent>
				<nContentKey/>
				<nContentPrimaryId/>
				<nVersion/>
				<cContentForiegnRef/>
				<cContentName/>
				<cContentSchemaName>xFormQuiz</cContentSchemaName>
				<cContentXmlBrief>
					<Content>
						<name/>
						<description/>
					</Content>
				</cContentXmlBrief>
				<cContentXmlDetail>
					<Content id="" ref="" name="" type="">
						<model class="ewXform">
							<instance>
								<results>
									<answers/>
									<grades>
										<grade passmark="" validDays="" validForever="">Pass</grade>
										<grade passmark="" validDays="" validForever="">Distinction</grade>
									</grades>
									<retakeLimit days="0" invalidForever=""/>
									<timelimit secs="0"/>
								</results>
							</instance>
							<submission method="post" action="" id="send"/>
						</model>
						<group ref="RootGroup" class="DefaultExam" presentation="StepThroughGroups" order="InOrder" qcount="0">
							<label/>
							<div class="description"/>
							<div class="recRead"/>
						</group>
					</Content>
				</cContentXmlDetail>
				<nAuditId/>
				<nAuditKey/>
				<dPublishDate/>
				<dExpireDate/>
				<dInsertDate/>
				<nInsertDirId/>
				<dUpdateDate/>
				<nUpdateDirId/>
				<nStatus/>
				<cDescription/>
			</tblContent>
		</instance>
		<submission id="EditContent" action="" method="post" event="return form_check(this)"/>
		<bind id="cContentSchemaName" nodeset="tblContent/cContentSchemaName" required="true()" type="string"/>
		<bind id="cContentName" nodeset="tblContent/cContentName" required="true()" type="string"/>
		<bind id="cContentName" nodeset="tblContent/cContentXmlBrief/Content/name" required="false()" type="string"/>
		<bind id="cContentName" nodeset="tblContent/cContentXmlDetail/Content/group/label" required="false()" type="string"/>
		<bind id="cContentForiegnRef" nodeset="tblContent/cContentForiegnRef" required="false()" type="string"/>
		<bind id="cContentDescription" nodeset="tblContent/cContentXmlBrief/Content/description" required="false()" type="string"/>
		<bind id="cContentDescription" nodeset="tblContent/cContentXmlDetail/Content/group/div[@class='description']" required="false()" type="string"/>
		<bind id="cPresentation" nodeset="tblContent/cContentXmlDetail/Content/group/@presentation" required="true()" type="string"/>
		<bind id="cClass" nodeset="tblContent/cContentXmlDetail/Content/group/@class" required="true()" type="string"/>
		<bind id="nOrder" nodeset="tblContent/cContentXmlDetail/Content/group/@order" required="true()" type="string"/>
		<bind id="nQcount" nodeset="tblContent/cContentXmlDetail/Content/group/@qcount" required="true()" type="string"/>
		<bind id="nPassMark" nodeset="tblContent/cContentXmlDetail/Content/model/instance/results/grades/grade[node()='Pass']/@passmark" required="true()" type="number"/>
		<bind id="nPassValid" nodeset="tblContent/cContentXmlDetail/Content/model/instance/results/grades/grade[node()='Pass']/@validDays" required="true()" type="number"/>
		<bind id="nPassValidForever" nodeset="tblContent/cContentXmlDetail/Content/model/instance/results/grades/grade[node()='Pass']/@validForever" required="false()" type="string"/>
		<bind id="nDistinctionMark" nodeset="tblContent/cContentXmlDetail/Content/model/instance/results/grades/grade[node()='Distinction']/@passmark" required="true()" type="number"/>
		<bind id="nDistinctionValid" nodeset="tblContent/cContentXmlDetail/Content/model/instance/results/grades/grade[node()='Distinction']/@validDays" required="true()" type="number"/>
		<bind id="nDistinctionValidForever" nodeset="tblContent/cContentXmlDetail/Content/model/instance/results/grades/grade[node()='Distinction']/@validForever" required="false()" type="string"/>
		<bind id="nRetakeDays" nodeset="tblContent/cContentXmlDetail/Content/model/instance/results/retakeLimit/@days" required="true()" type="number"/>
		<bind id="nFailInvalidForever" nodeset="tblContent/cContentXmlDetail/Content/model/instance/results/retakeLimit/@invalidForever" required="false()" type="string"/>
		<bind id="nTimeLimitSecs" nodeset="tblContent/cContentXmlDetail/Content/model/instance/results/timelimit/@secs" required="true()" type="number"/>
		<bind id="cContentXmlBrief" nodeset="tblContent/cContentXmlBrief" required="false()" type="string"/>
		<bind id="dPublishDate" nodeset="tblContent/dPublishDate" required="false()" type="string"/>
		<bind id="dExpireDate" nodeset="tblContent/dExpireDate" required="false()" type="string"/>
		<bind id="nStatus" nodeset="tblContent/nStatus" required="true()" type="string"/>
		<bind id="cDescription" nodeset="tblContent/cDescription" required="false()" type="string"/>
		<!--bind id="cContentRecRead" nodeset="tblContent/cContentXmlDetail/Content/group/div[@class='recRead']" required="false()" type="string"/-->
	</model>
	<group ref="EditContent" class="2Col">
		<label>Edit Quiz / Exam</label>
		<input bind="nContentKey" class="hidden">
			<label>ContentId</label>
		</input>
		<input bind="cContentSchemaName" class="hidden">
			<label>cContentSchemaName</label>
			<value>xFormQuiz</value>
		</input>
		<group ref="Settings">
			<label>Quiz / Exam Settings</label>
			<input bind="cContentName" class="required">
				<label>Quiz Name</label>
			</input>
			<input bind="cContentForiegnRef">
				<label>Quiz Ref</label>
			</input>
			<select1 bind="cPresentation" appearance="minimal" class="required">
				<label>Presentation</label>
				<!--item>
					<label>ShowAll</label>
					<value>ShowAll</value>
				</item>
				<item>
					<label>ShowAll and HideAnswers</label>
					<value>ShowAll HideAnswers</value>
				</item-->
				<item>
					<label>Step Through Groups as Pages</label>
					<value>StepThroughGroups</value>
				</item>
				<item>
					<label>Step Through Groups as Pages and HideAnswers</label>
					<value>StepThroughGroups HideAnswers</value>
				</item>
				<value/>
			</select1>
			<select1 bind="cClass" appearance="minimal" class="required">
				<label>Style</label>
				<item>
					<label>Default Exam</label>
					<value>DefaultExam</value>
				</item>
				<item>
					<label>Default Quiz</label>
					<value>DefaultQuiz</value>
				</item>
				<item>
					<label>Diploma England</label>
					<value>DimplomaEngland</value>
				</item>
				<item>
					<label>Diploma Scotland</label>
					<value>DiplomaScotland</value>
				</item>
				<item>
					<label>Diploma Wales</label>
					<value>DiplomaWales</value>
				</item>
				<item>
					<label>Diploma Northern Ireland</label>
					<value>Diploma Northern Ireland</value>
				</item>
				<item>
					<label>ABPI</label>
					<value>ABPI</value>
				</item>
				<value/>
			</select1>
			<select1 bind="nOrder" appearance="minimal" class="required">
				<label>Page Sequence</label>
				<item>
					<label>Random</label>
					<value>random</value>
				</item>
				<item>
					<label>In Order</label>
					<value>InOrder</value>
				</item>
			</select1>
			<input bind="nQcount" class="required">
				<label>No. of Questions to Ask</label>
				<help>0 = all questions</help>
				<value/>
			</input>
			<input bind="nPassMark" class="required">
				<label>Pass Mark</label>
			</input>
			<input bind="nPassValid" class="required">
				<label>Pass valid for (Days)</label>
			</input>
			<select bind="nPassValidForever" appearance="full">
				<choices/>
				<label>Pass never expires</label>
				<help>When selected, this overrides the Pass Valid option</help>
				<item>
					<label/>
					<value>true</value>
				</item>
				<value/>
			</select>
			<input bind="nDistinctionMark" class="required">
				<label>Distinction Mark</label>
			</input>
			<input bind="nDistinctionValid" class="required">
				<label>Distinction valid for (Days)</label>
			</input>
			<select bind="nDistinctionValidForever" appearance="full">
				<choices/>
				<label>Distinction never expires</label>
				<help>When selected, this overrides the Distinction Valid option</help>
				<item>
					<label/>
					<value>true</value>
				</item>
				<value/>
			</select>
			<input bind="nRetakeDays" class="required">
				<label>No. of days before retake</label>
				<help>0 = straight away</help>
				<value/>
			</input>
			<select bind="nFailInvalidForever" appearance="full">
				<choices/>
				<label>Failure Lasts Forever</label>
				<help>When selected, this overrides the Retake Days option</help>
				<item>
					<label/>
					<value>true</value>
				</item>
				<value/>
			</select>
			<input bind="nTimeLimitSecs" class="required">
				<label>Time Limit (Seconds)</label>
				<help>0 = no limit</help>
				<value/>
			</input>
			<input bind="dPublishDate" class="calendar">
				<label>Publish Date</label>
			</input>
			<input bind="dExpireDate" class="calendar">
				<label>Expire Date</label>
			</input>
			<select1 bind="nStatus" appearance="minimal" class="required">
				<label>Status</label>
				<choices/>
				<item>
					<label>Live</label>
					<value>1</value>
				</item>
				<item>
					<label>Hidden</label>
					<value>0</value>
				</item>
			</select1>
			<input bind="cDescription">
				<label>Change Notes</label>
			</input>
		</group>
		<group ref="Content">
			<label>Other Information</label>
			<textarea bind="cContentDescription" class="TextAreaBrief xhtml" rows="10" cols="70">
				<label>Instructions</label>
			</textarea>
			<!--textarea bind="cContentRecRead" class="TextAreaBrief xhtml" rows="10" cols="70">
				<label>Recommended Reading</label>
			</textarea-->
			<input bind="cContentXmlDetail" class="editXformButton">
				<label>Edit Quiz / Exam</label>
			</input>
		</group>
		<submit submission="" ref="ewSubmit" class="principle">
			<label>Save Questionnaire</label>
		</submit>
	</group>
</Content>
